<style lang="less">
  .cls {
    width: 300px;
  }
</style>

<template>
  <div>
    <el-col :span="24">
      style设置:
      <address-select v-model="options" :style="{width:'400px'}" :disabled="1==1"></address-select>
      <el-button @click="getVal">获取值</el-button>
      <el-button @click="setVal">设值</el-button>
    </el-col>
    <el-col :span="24">
      class设置:
      <address-select v-model="options" :class="'cls'"></address-select>
    </el-col>
    <el-col :span="24">
      事件处理:
      <address-select v-model="options" @change="change"></address-select>
    </el-col>
  </div>
</template>

<script>
  export default{
    data () {
      return {
        options: []
      };
    },
    methods: {
      getVal () {
        alert(this.options.join(','));
        console.log(this.options);
      },
      change (val) {
        console.log(val);
        alert(val.join(','));
      },
      setVal () {
        this.options = ['110000', '110100', '110101'];
      }
    }
  };
</script>
